package com.yc.taixin.model;


import com.alibaba.fastjson.annotation.JSONField;
import org.springframework.format.annotation.DateTimeFormat;

import javax.persistence.*;
import java.io.Serializable;
import java.util.Date;

@SuppressWarnings("serial")
@Entity
@Table(name = "t_s_order")
@org.hibernate.annotations.Table(appliesTo = "t_s_order", comment = "订单表")
public class TSOrder extends IdEntity implements Serializable {

	/*@Column(columnDefinition = "varchar(500) DEFAULT NULL COMMENT '设备名称'")
	@Column(columnDefinition = "int default 0 comment '排序字段'")
	private int odr;

	@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	@Temporal(TemporalType.TIMESTAMP)
	@JSONField(format = "yyyy-MM-dd HH:mm:ss")
	@Column(columnDefinition = "datetime DEFAULT NULL COMMENT '创建时间'")
	private Date buildtime;*/

	private String orderName;// 订单名

	private Date createDate;

	@Column(columnDefinition = "varchar(50) DEFAULT NULL UNIQUE COMMENT '订单名'")
	public String getOrderName() {
		return orderName;
	}

	public void setOrderName(String orderName) {
		this.orderName = orderName;
	}

	@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	@Temporal(TemporalType.TIMESTAMP)
	@JSONField(format = "yyyy-MM-dd HH:mm:ss")
	@Column(columnDefinition = "datetime DEFAULT NULL COMMENT '创建的时间'")
	public Date getCreateDate() {
		return createDate;
	}

	public void setCreateDate(Date createDate) {
		this.createDate = createDate;
	}

}
